package com.ruoyi.project.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.system.mapper.SysTypeDetailMapper;
import com.ruoyi.project.system.domain.SysTypeDetail;
import com.ruoyi.project.system.service.ISysTypeDetailService;

/**
 * 分类详情Service业务层处理
 * 
 * @author jjp
 * @date 2020-04-16
 */
@Service
public class SysTypeDetailServiceImpl implements ISysTypeDetailService 
{
    @Autowired
    private SysTypeDetailMapper sysTypeDetailMapper;

    /**
     * 查询分类详情
     * 
     * @param typeDetailId 分类详情ID
     * @return 分类详情
     */
    @Override
    public SysTypeDetail selectSysTypeDetailById(Long typeDetailId)
    {
        return sysTypeDetailMapper.selectSysTypeDetailById(typeDetailId);
    }

    /**
     * 查询分类详情列表
     * 
     * @param sysTypeDetail 分类详情
     * @return 分类详情
     */
    @Override
    public List<SysTypeDetail> selectSysTypeDetailList(SysTypeDetail sysTypeDetail)
    {
        return sysTypeDetailMapper.selectSysTypeDetailList(sysTypeDetail);
    }

    /**
     * 新增分类详情
     * 
     * @param sysTypeDetail 分类详情
     * @return 结果
     */
    @Override
    public int insertSysTypeDetail(SysTypeDetail sysTypeDetail)
    {
        return sysTypeDetailMapper.insertSysTypeDetail(sysTypeDetail);
    }

    @Override
    public SysTypeDetail selectSysTypeIdById(Long typeDetailId) {
        return sysTypeDetailMapper.selectSysTypeIdById(typeDetailId);
    }

    /**
     * 修改分类详情
     * 
     * @param sysTypeDetail 分类详情
     * @return 结果
     */
    @Override
    public int updateSysTypeDetail(SysTypeDetail sysTypeDetail)
    {
        return sysTypeDetailMapper.updateSysTypeDetail(sysTypeDetail);
    }

    /**
     * 批量删除分类详情
     * 
     * @param typeDetailIds 需要删除的分类详情ID
     * @return 结果
     */
    @Override
    public int deleteSysTypeDetailByIds(Long[] typeDetailIds)
    {
        return sysTypeDetailMapper.deleteSysTypeDetailByIds(typeDetailIds);
    }

    /**
     * 删除分类详情信息
     * 
     * @param typeDetailId 分类详情ID
     * @return 结果
     */
    @Override
    public int deleteSysTypeDetailById(Long typeDetailId)
    {
        return sysTypeDetailMapper.deleteSysTypeDetailById(typeDetailId);
    }
}
